<?php if(count($this->popArr)<10){ ?>
<?php
/**
 * OrangeHRM is a comprehensive Human Resource Management (HRM) System that captures
 * all the essential functionalities required for any enterprise.
 * Copyright (C) 2006 OrangeHRM Inc., http://www.orangehrm.com
 *
 * OrangeHRM is free software; you can redistribute it and/or modify it under the terms of
 * the GNU General Public License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * OrangeHRM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with this program;
 * if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA  02110-1301, USA
 */
//if(count($this->popArr)<10){
require_once ROOT_PATH . '/lib/confs/sysConf.php';
$sysConst = new sysConf();
$maxDispLen = $sysConst->viewDescLen;

$locRights = $_SESSION['localRights'];
$locRights['view']=true;
/*
 * Chinh Nguyen add
 */
/*
if ($_SESSION['isAdmin']=='Yes' ) {
    $locRights = array('add'=> true , 'edit'=> true , 'delete'=> true, 'view'=> true);
}else {
	$locRights = array('add'=> false , 'edit'=> false , 'delete'=> false, 'view'=> true);
}
*/
//error_log($locRights['add'],3,"C:/logtest.log");
$currentPage = $this->popArr['currentPage'];

$list = $this->popArr['list'];
$baseURL = './CentralController.php?newscode='. $this->getArr['newscode'];//Chinh Nguyen command this
//$baseURL = './CentralController.php?newscode=Vacancy'. $this->getArr['newscode'];

if(count($this->popArr)==4)
{
$type = $this->popArr['type'];
if($type==1)
	$typeTitle = "News";
if($type==2)
	$typeTitle = "Events";
if($type==3)
	$typeTitle = "Announcements";
}
else{
	$typeTitle ="Home";
}
$allowAdd = $locRights['add'];
//error_log($locRights['add'],3,"C:/logtest.log");
$allowDelete = $locRights['delete'];

if (!isset($this->getArr['sortField']) || ($this->getArr['sortField'] == '')) {
	$this->getArr['sortField']=0;
	$this->getArr['sortOrder0']='ASC';
}

function getNextSortOrder($curSortOrder) {
	switch ($curSortOrder) {
		case 'null' :
			return 'ASC';
			break;
		case 'ASC' :
			return 'DESC';
			break;
		case 'DESC'	:
			return 'ASC';
			break;
	}
}

function getSortOrderInWords($SortOrder) {
	if ($SortOrder == 'ASC') {
		return 'Ascending';
	} else {
		return 'Descending';
	}
}

function getDisplayValue($value, $map, $maxLen) {


	if (!empty($map) && isset($map[$value])) {
	    $value = $map[$value];
	}

	if ($maxLen <= strlen($value)) {
		$value = substr($value, 0, $maxLen) . '....';
	}
	return $value;
}

function getDisplaySummary($value, $maxLen) {


	if (isset($value)) {
	    $value = $value;
	}

	if ($maxLen <= strlen($value)) {
		$value = substr($value, 0, $maxLen) . '....';
	}
	return $value;
}

$searchStr = isset($this->postArr['loc_name'])? stripslashes($this->postArr['loc_name']) : '';
if (isset($this->postArr['loc_code'])) {
	$code = $this->postArr['loc_code'];
	if (isset($valueMap[$code])){
		$searchStr = getDisplayValue($searchStr, $valueMap[$code], $maxDispLen);
	}
}

$themeDir = '../../themes/' . $styleSheet;
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="<?php echo $themeDir;?>/css/style.css" rel="stylesheet" type="text/css">
<style type="text/css">@import url("<?php echo $themeDir;?>/css/style.css"); </style>
<style type="text/css">

    .roundbox {
        margin-top: 0px;
        margin-left: 0px;
        width: 750px;
      
    }

    .roundbox_content {
        padding-bottom:15px;
    }
    tr.row_highlight:hover td{background:#99ccff}
</style>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript" src="../../scripts/archive.js"></script>
<script type="text/javascript" src="../../scripts/octopus.js"></script>
</head>
<script type="text/javascript">

	// Maps to allow searching of mapped values
    var maps = new Array();
<?php
for ($i = 0; $i < count($valueMap); $i++) {
	echo "maps[{$i}] = new Array();\n";
	if (!empty($valueMap[$i]) && is_array($valueMap[$i])) {
	    foreach($valueMap[$i] as $key=>$value) {
			echo "maps[{$i}]['{$value}'] = '$key';\n";
	    }
	}
}
?>
	function nextPage() {
		var i=eval(document.standardView.pageNO.value);
		document.standardView.pageNO.value=i+1;
		document.standardView.submit();
	}

	function prevPage() {
		var i=eval(document.standardView.pageNO.value);
		document.standardView.pageNO.value=i-1;
		document.standardView.submit();
	}

	function chgPage(pNO) {
		document.standardView.pageNO.value=pNO;
		document.standardView.submit();
	}

	function sortAndSearch(fieldNum, sortOrder) {
		var url = '<?php echo $baseURL;?>&action=<?php echo $this->getArr['action'];?>';
		action = url + '&sortField=' + fieldNum + '&sortOrder' + fieldNum + '=' + sortOrder;

		document.standardView.action = action;
		document.standardView.submit();
	}

	function returnAdd() {
		location.href = '<?php echo $baseURL;?>&action=ViewAdd';
	}

	function returnDelete() {
		var check = false;
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if ((elements[i].type == 'checkbox') && (elements[i].checked == true) && (elements[i].name == 'chkID[]')){
					check = true;
					break;
				}
			}
		}

		if (check){

			var res = confirm("<?php echo $deletePrompt . ' ' . $lang_Common_ConfirmDelete; ?>");
			if (!res) {
			    return false;
			}

			document.standardView.action="<?php echo $baseURL;?>&action=Delete";
			document.standardView.pageNO.value=1;
			document.standardView.submit();
		} else {
			alert("<?php echo $lang_Common_SelectDelete; ?>");
		}
	}

	function returnSearch() {

		searchBy = $('loc_code');

		if (searchBy.options[searchBy.selectedIndex].value == -1) {
			alert("<?php echo $lang_Common_SelectField; ?>");
			searchBy.focus();
			return;
		};
		searchNdx = searchBy.options[searchBy.selectedIndex].value;
		var searchVal = $('loc_name').value;

		if (searchNdx == 3) {
		    map = maps[searchNdx];
		    if (searchVal in map) {
		        $('loc_name').value = map[searchVal];
		    } else {
		        var len = map.length;
		        var allowed = '';
		        for ( var i in map) {
		        	if (allowed == ''){
		            	allowed = i;
		        	} else {
		            	allowed = allowed + ', ' + i;
		            }
		        }
		        alert("<?php echo $lang_Recruit_AllowedValuesAre;?> " + allowed);
		        return;
		    }
		}

		document.standardView.captureState.value = 'SearchMode';
		document.standardView.pageNO.value=1;
		document.standardView.submit();
	}

	function doHandleAll() {
		with (document.standardView) {
			if(elements['allCheck'].checked == false){
				doUnCheckAll();
			}
			else if(elements['allCheck'].checked == true){
				doCheckAll();
			}
		}
	}

	function doCheckAll() {
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if (elements[i].type == 'checkbox') {
					elements[i].checked = true;
				}
			}
		}
	}

	function doUnCheckAll() {
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if (elements[i].type == 'checkbox') {
					elements[i].checked = false;
				}
			}
		}
	}

	function clear_form() {
		document.standardView.loc_code.options[0].selected=true;
		document.standardView.loc_name.value='';
	}
</script>
<body style="background-color: #FFFFFF;">
<form name="standardView" id="standardView" method="post" action="<?php echo $baseURL;?>&action=<?php echo $this->getArr['action'];?>&sortField=<?php echo $this->getArr['sortField']?>&sortOrder<?php echo $this->getArr['sortField']?>=<?php echo $this->getArr['sortOrder'.$this->getArr['sortField']];?>">
	<!-- <div class="listViewThS1" style="padding: 6px;"><h2></h2></div>
	 -->
	<?php if($allowDelete || $allowAdd){ ?>
	<div>
		<input type="hidden" name="captureState" value="<?php echo isset($this->postArr['captureState'])?$this->postArr['captureState']:''?>" />
		<input type="hidden" name="pageNO" value="<?php echo isset($this->postArr['pageNO'])?$this->postArr['pageNO']:'1'?>" />
		<div style="padding: 3px;">
		<?php	if($allowAdd) { ?>
		<img
			style="border: none"
			title="Add"
			alt="Add"
			src="<?php echo $themeDir;?>/pictures/btn_add.gif"
			onclick="returnAdd();"
			onmouseout="this.src='<?php echo $themeDir;?>/pictures/btn_add.gif';"
			onmouseover="this.src='<?php echo $themeDir;?>/pictures/btn_add_02.gif';" />
		<?php	} ?>

		<?php if($allowDelete) { ?>
		<img
			style="border: none"
	   		title="Delete"
	   		alt="Delete"
			src="<?php echo $themeDir;?>/pictures/btn_delete.gif"
			onclick="returnDelete();"
			onmouseout="this.src='<?php echo $themeDir;?>/pictures/btn_delete.gif';"
			onmouseover="this.src='<?php echo $themeDir;?>/pictures/btn_delete_02.gif';" />
		<?php } ?>
		</div>
	</div>	
	<?php } ?>


	<?php if($this->popArr['count']>10){ ?>
	<div style="text-align: right; padding-top: 2px; width: 98%">
		<?php
		$temp = $this->popArr['count'];
		$commonFunc = new CommonFunctions();
		$pageStr = $commonFunc->printPageLinks($temp, $currentPage);
		$pageStr = preg_replace(array('/#first/', '/#previous/', '/#next/', '/#last/'), array($lang_empview_first, $lang_empview_previous, $lang_empview_next, $lang_empview_last), $pageStr);

		echo $pageStr;
		?>&nbsp;
	</div>
	<?php }?>

	<div >
		<table width="100%" border="0" cellpadding="5" cellspacing="0" class="">
		  <tr style="white-space: nowrap">
			<td colspan="2" nowrap="nowrap" class="listViewThS1" style="color:#E52828; font-size:16px;">
				<?php echo $typeTitle; ?>
			</td>
			</tr>
			<?php
				if ((isset($list)) && ($list !='')) {
					for ($j=0; $j < count($list);$j++) {
						$cssClass = ($j%2) ? 'even' : 'odd';
						if (CommonFunctions::extractNumericId($list[$j][0]) > 0) {
							if($allowDelete) {?>
							<tr class="row_highlight">
								<td class="<?php echo $cssClass?>" width="5" align="left">										
									<input type='checkbox' class='checkbox' name='chkID[]' value='<?php echo $list[$j][0]?>'></input>										
								</td>									
								<td class="<?php echo $cssClass?>" align="left" >
									<a style="text-decoration: none;" href="<?php echo $baseURL . '&id='. $list[$j][0];?>&amp;action=View" class="listViewTdLinkS1"><span class="newsTitle"><?php echo $list[$j][1]?></span><span class="nd_bold"> (<?php echo $list[$j][3]; ?>)</span></a>
								</td>									
							</tr>
							<tr>
								<td colspan="2" class="<?php echo $cssClass?>" align="left">
									<table cellpadding="0" cellspacing="0" border="0">
										<tr>
											<td align="left">
												<?php echo $list[$j][5];?>
											</td>
										</tr>
									</table>													
								</td>
							</tr>
					<?php }else{ ?>
							<tr class="row_highlight">																			
								<td class="<?php echo $cssClass?>" align="left">
									<a style="text-decoration: none;" href="<?php echo $baseURL . '&id='. $list[$j][0];?>&amp;action=View" class="listViewTdLinkS1"><span class="newsTitle"><?php echo $list[$j][1]?></span><span class="nd_bold"> (<?php echo $list[$j][3]; ?></span>)</a>
								</td>									
							</tr>
							<tr>
								<td  class="<?php echo $cssClass?>" align="left">
									<table cellpadding="0" cellspacing="0" border="0">
										<tr>
											<td align="left">
												<?php echo $list[$j][5]; ?>
											</td>
										</tr>
									</table>													
								</td>
							</tr>
					<?php } 
						}
					}
				}
			?>
		</table>
	</div>
		<div style="padding-top: 2px; width: 98%">
		<span id="messageDisplay">
			<?php
			if (empty($list)) {
					echo $dispMessage;
			}
			?>&nbsp;
		</span>
	</div>
</form>

<script type="text/javascript">
<!--
   	if (document.getElementById && document.createElement) {
		initOctopus();
	}
-->
</script>

</body>
</html>


<?php }else { ?>

<?php
/**
 * OrangeHRM is a comprehensive Human Resource Management (HRM) System that captures
 * all the essential functionalities required for any enterprise.
 * Copyright (C) 2006 OrangeHRM Inc., http://www.orangehrm.com
 *
 * OrangeHRM is free software; you can redistribute it and/or modify it under the terms of
 * the GNU General Public License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * OrangeHRM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with this program;
 * if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA  02110-1301, USA
 */
//if(count($this->popArr)<10){
require_once ROOT_PATH . '/lib/confs/sysConf.php';
$sysConst = new sysConf();
$maxDispLen = $sysConst->viewDescLen;

$locRights = $_SESSION['localRights'];
$locRights['view']=true;
/*
 * Chinh Nguyen add
 */
/*
if ($_SESSION['isAdmin']=='Yes' ) {
    $locRights = array('add'=> true , 'edit'=> true , 'delete'=> true, 'view'=> true);
}else {
	$locRights = array('add'=> false , 'edit'=> false , 'delete'=> false, 'view'=> true);
}
*/
//error_log($locRights['add'],3,"C:/logtest.log");
$currentPage = $this->popArr['currentPage'];

$listNews = $this->popArr['listNews'];
$listEvent = $this->popArr['listEvent'];
$listAnnounce = $this->popArr['listAnnounce'];
$listHot = $this->popArr['listHot'];
$baseURL = './CentralController.php?newscode='. $this->getArr['newscode'];//Chinh Nguyen command this
//$baseURL = './CentralController.php?newscode='. $this->getArr['newscode'];

if(count($this->popArr)<10)
{
$type = $this->popArr['type'];
if($type==1)
	$typeTitle = "News";
if($type==2)
	$typeTitle = "Events";
if($type==3)
	$typeTitle = "Announcements";
if($type==4)
	$typeTitle = "Hot News";
}
else{
	$typeTitle ="Home";
}
$allowAdd = $locRights['add'];
//error_log($locRights['add'],3,"C:/logtest.log");
$allowDelete = $locRights['delete'];

if (!isset($this->getArr['sortField']) || ($this->getArr['sortField'] == '')) {
	$this->getArr['sortField']=0;
	$this->getArr['sortOrder0']='ASC';
}

function getNextSortOrder($curSortOrder) {
	switch ($curSortOrder) {
		case 'null' :
			return 'ASC';
			break;
		case 'ASC' :
			return 'DESC';
			break;
		case 'DESC'	:
			return 'ASC';
			break;
	}
}

function getSortOrderInWords($SortOrder) {
	if ($SortOrder == 'ASC') {
		return 'Ascending';
	} else {
		return 'Descending';
	}
}

function getDisplayValue($value, $map, $maxLen) {


	if (!empty($map) && isset($map[$value])) {
	    $value = $map[$value];
	}

	if ($maxLen <= strlen($value)) {
		$value = substr($value, 0, $maxLen) . '....';
	}
	return $value;
}

function getDisplaySummary($value, $maxLen) {


	if (isset($value)) {
	    $value = $value;
	}

	if ($maxLen <= strlen($value)) {
		$value = substr($value, 0, $maxLen) . '....';
	}
	return $value;
}

$searchStr = isset($this->postArr['loc_name'])? stripslashes($this->postArr['loc_name']) : '';
if (isset($this->postArr['loc_code'])) {
	$code = $this->postArr['loc_code'];
	if (isset($valueMap[$code])){
		$searchStr = getDisplayValue($searchStr, $valueMap[$code], $maxDispLen);
	}
}

$themeDir = '../../themes/' . $styleSheet;
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="<?php echo $themeDir;?>/css/style.css" rel="stylesheet" type="text/css">
<style type="text/css">@import url("<?php echo $themeDir;?>/css/style.css"); </style>
<link href="../../themes/<?php echo $styleSheet;?>/css/button.css" rel="stylesheet" type="text/css" />
<style type="text/css">

    .roundbox {
        margin-top: 5px;
        margin-left: 0px;
        width: 98%;
    }

    .roundbox_content {
    	padding-top:0px;
        padding-bottom:15px;
    }
    tr.row_highlight:hover td{background:#99ccff}
</style>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript" src="../../scripts/archive.js"></script>
<script type="text/javascript" src="../../scripts/octopus.js"></script>
</head>
<script type="text/javascript">

	// Maps to allow searching of mapped values
    var maps = new Array();
<?php
for ($i = 0; $i < count($valueMap); $i++) {
	echo "maps[{$i}] = new Array();\n";
	if (!empty($valueMap[$i]) && is_array($valueMap[$i])) {
	    foreach($valueMap[$i] as $key=>$value) {
			echo "maps[{$i}]['{$value}'] = '$key';\n";
	    }
	}
}
?>
	function nextPage() {
		var i=eval(document.standardView.pageNO.value);
		document.standardView.pageNO.value=i+1;
		document.standardView.submit();
	}

	function prevPage() {
		var i=eval(document.standardView.pageNO.value);
		document.standardView.pageNO.value=i-1;
		document.standardView.submit();
	}

	function chgPage(pNO) {
		document.standardView.pageNO.value=pNO;
		document.standardView.submit();
	}

	function sortAndSearch(fieldNum, sortOrder) {
		var url = '<?php echo $baseURL;?>&action=<?php echo $this->getArr['action'];?>';
		action = url + '&sortField=' + fieldNum + '&sortOrder' + fieldNum + '=' + sortOrder;

		document.standardView.action = action;
		document.standardView.submit();
	}

	function returnAdd() {
		location.href = '<?php echo $baseURL;?>&action=ViewAdd';
	}

	function returnDelete() {
		var check = false;
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if ((elements[i].type == 'checkbox') && (elements[i].checked == true) && (elements[i].name == 'chkID[]')){
					check = true;
					break;
				}
			}
		}

		if (check){

			var res = confirm("<?php echo $deletePrompt . ' ' . $lang_Common_ConfirmDelete; ?>");
			if (!res) {
			    return false;
			}

			document.standardView.action="<?php echo $baseURL;?>&action=Delete";
			document.standardView.pageNO.value=1;
			document.standardView.submit();
		} else {
			alert("<?php echo $lang_Common_SelectDelete; ?>");
		}
	}

	function returnSearch() {

		searchBy = $('loc_code');

		if (searchBy.options[searchBy.selectedIndex].value == -1) {
			alert("<?php echo $lang_Common_SelectField; ?>");
			searchBy.focus();
			return;
		};
		searchNdx = searchBy.options[searchBy.selectedIndex].value;
		var searchVal = $('loc_name').value;

		if (searchNdx == 3) {
		    map = maps[searchNdx];
		    if (searchVal in map) {
		        $('loc_name').value = map[searchVal];
		    } else {
		        var len = map.length;
		        var allowed = '';
		        for ( var i in map) {
		        	if (allowed == ''){
		            	allowed = i;
		        	} else {
		            	allowed = allowed + ', ' + i;
		            }
		        }
		        alert("<?php echo $lang_Recruit_AllowedValuesAre;?> " + allowed);
		        return;
		    }
		}

		document.standardView.captureState.value = 'SearchMode';
		document.standardView.pageNO.value=1;
		document.standardView.submit();
	}

	function doHandleAll() {
		with (document.standardView) {
			if(elements['allCheck'].checked == false){
				doUnCheckAll();
			}
			else if(elements['allCheck'].checked == true){
				doCheckAll();
			}
		}
	}

	function doCheckAll() {
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if (elements[i].type == 'checkbox') {
					elements[i].checked = true;
				}
			}
		}
	}

	function doUnCheckAll() {
		with (document.standardView) {
			for (var i=0; i < elements.length; i++) {
				if (elements[i].type == 'checkbox') {
					elements[i].checked = false;
				}
			}
		}
	}

	function clear_form() {
		document.standardView.loc_code.options[0].selected=true;
		document.standardView.loc_name.value='';
	}
</script>
<body style="background-color: #FFFFFF;">
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td>
<form name="standardView" id="standardView" method="post" action="<?php echo $baseURL;?>&action=<?php echo $this->getArr['action'];?>&sortField=<?php echo $this->getArr['sortField']?>&sortOrder<?php echo $this->getArr['sortField']?>=<?php echo $this->getArr['sortOrder'.$this->getArr['sortField']];?>">
	<div>
		<input type="hidden" name="captureState" value="<?php echo isset($this->postArr['captureState'])?$this->postArr['captureState']:''?>" />
		<input type="hidden" name="pageNO" value="<?php echo isset($this->postArr['pageNO'])?$this->postArr['pageNO']:'1'?>" />
		<div style="padding: 3px;text-align: left;">
		<?php	if($allowAdd) { ?>
		<img
			style="border: none"
			title="Add"
			alt="Add"
			src="<?php echo $themeDir;?>/pictures/btn_add.gif"
			onclick="returnAdd();"
			onmouseout="this.src='<?php echo $themeDir;?>/pictures/btn_add.gif';"
			onmouseover="this.src='<?php echo $themeDir;?>/pictures/btn_add_02.gif';" />
		<?php	} ?>

		<?php if($allowDelete) { ?>
		<img
			style="border: none"
	   		title="Delete"
	   		alt="Delete"
			src="<?php echo $themeDir;?>/pictures/btn_delete.gif"
			onclick="returnDelete();"
			onmouseout="this.src='<?php echo $themeDir;?>/pictures/btn_delete.gif';"
			onmouseover="this.src='<?php echo $themeDir;?>/pictures/btn_delete_02.gif';" />
		<?php } ?>
		</div>
	</div>
	<?php if($this->popArr['countHot']>10){ ?>
	<div style="text-align: right; padding-top: 2px; width: 98%">
		<?php
		$temp = $this->popArr['countHot'];
		$commonFunc = new CommonFunctions();
		$pageStr = $commonFunc->printPageLinks($temp, $currentPage);
		$pageStr = preg_replace(array('/#first/', '/#previous/', '/#next/', '/#last/'), array($lang_empview_first, $lang_empview_previous, $lang_empview_next, $lang_empview_last), $pageStr);
		echo $pageStr;
		?>&nbsp;
	</div>
	<?php }?>
	<div style="text-align: left;">
		<table width="100%" border="0" cellpadding="5" cellspacing="0" align="left">			
			<tr style="white-space: nowrap">
			<td colspan="4" nowrap="nowrap" class="listViewThS1" style="color:#E52828; font-size:16px;">
			Hot News
			</td>
			</tr>			
			<?php	
				
					if ((isset($listHot)) && ($listHot !='')) {
						for ($j=0; $j < count($listHot);$j++) {
							$cssClass = ($j%2) ? 'even' : 'odd';
							if (CommonFunctions::extractNumericId($listHot[$j][0]) > 0) {
							if($allowDelete) {
							?>
							<tr class="row_highlight">
								<td class="<?php echo $cssClass?>" width="5" align="left" nowrap="nowrap">
										<input type='checkbox' style="width: 10px" class='checkbox' name='chkID[]' value='<?php echo $listHot[$j][0]?>'></input>
								</td>
								<td  class="<?php echo $cssClass?>" align="left" >
									<a style="text-decoration: none; width: 10px" href="<?php echo $baseURL . '&id='. $listHot[$j][0];?>&amp;action=View" ><span class="newsTitle" ><?php echo  $listHot[$j][1];?> </span><span class="nd_bold">( <?php echo $listHot[$j][3]; ?> )</span> </a>
								</td>
							</tr>
							<tr>
								<td colspan="2" class="<?php echo $cssClass?>" >
									<table cellpadding="15" cellspacing="0" border="0">
									<tr>
									<td style="margin-bottom: 10px;" >
										<?php echo $listHot[$j][5]; ?>
														<p><a style="text-decoration: none;" href="<?php echo $baseURL . '&id='. $listHot[$j][0];?>&amp;action=View" ><span class="newsTitle"  >...</span></a></p>
									</td>
									</tr>
									</table>								
								</td>
							</tr>
							<?php }else{ ?>
						
							<tr class="row_highlight">								
								<td  class="<?php echo $cssClass?>" align="left" >
									<a style="text-decoration: none;" href="<?php echo $baseURL . '&id='. $listHot[$j][0];?>&amp;action=View" ><span class="newsTitle"  ><?php echo $listHot[$j][1]?></span><span class="nd_bold"> ( <?php echo $listHot[$j][3]; ?> )</span> </a>
								</td>
							</tr>
								<tr>
											<td  class="<?php echo $cssClass?>">
												<table cellpadding="15" cellspacing="0" border="0">
													<tr>
														<td >
															<?php echo $listHot[$j][5]; ?>
																<p><a style="text-decoration: none;" href="<?php echo $baseURL . '&id='. $listHot[$j][0];?>&amp;action=View" ><span class="newsTitle"  >...</span></a></p>
														</td>
													</tr>
												</table>													
											</td>
										</tr>
					
							<?php	}
						}
					}
				}
				?>
		</table>
	</div>
	<?php if($this->popArr['countHot']>10){ ?>
	<div style="text-align: right; padding-top: 2px; width: 98%">
		<?php
		$temp = $this->popArr['countHot'];
		$commonFunc = new CommonFunctions();
		$pageStr = $commonFunc->printPageLinks($temp, $currentPage);
		$pageStr = preg_replace(array('/#first/', '/#previous/', '/#next/', '/#last/'), array($lang_empview_first, $lang_empview_previous, $lang_empview_next, $lang_empview_last), $pageStr);

		echo $pageStr;
		?>&nbsp;
	</div>
	<?php }?>
	<div style="padding-top: 2px; width: 98%">
		<span id="messageDisplay">
			<?php
			if (empty($listHot)) {
					echo $dispMessage;
			}
			?>&nbsp;
		</span>
	</div>
</form>
													</td>
												</tr>
											</table>								
</body>
</html>

<?php } ?>
